package com.example.remindme.RemindModule.DataCard.ViewHolder

import android.view.View
import android.widget.ImageView
import android.widget.TextView
import androidx.recyclerview.widget.RecyclerView
import com.example.remindme.R

class ViewHolderList(val root: View): RecyclerView.ViewHolder(root) {
    val img:ImageView=root.findViewById(R.id.listImage)
    val listNmae:TextView=root.findViewById(R.id.list_name)
    fun bind(data: RecyclerData)
    {
        // 把对应的block与布局结合起来就行
        if(data is MyList)
        {
            listNmae.text=data.listType
        }
        img.setBackgroundColor(root.resources.getColor(R.color.white))

    }
}